<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateUserDeviceInfoTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('user_device_info', function (Blueprint $table) {
            $table->increments('id');
            $table->string('user_mobile',20)->comment('用户号码');
            $table->string('register_source',128)->default('')->comment('注册来源');
            $table->string('device_id',128)->default('')->comment('设备id号');
            $table->string('os_version',32)->comment('系统版本');
            $table->string('phone_type',128)->comment('手机型号');
            $table->string('ip',32)->default('')->comment('注册ip');
            $table->string('register_area',128)->default('')->comment('注册地区');
            $table->string('ios_or_android',32)->default('')->comment('判断是安卓还是iOS');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::drop('user_device_info');
    }
}
